<%@ page contentType="text/html; charset=UTF-8" errorPage="/jsp/error.jsp" %>

<%@ taglib uri="/WEB-INF/tlds/struts-bean.tld"  prefix="bean" %>
<%@ taglib uri="/WEB-INF/tlds/struts-template.tld" prefix="template" %>

<%@ page import="com.erp.app.report.genericInquiry.inquiryMaster.beans.*" %>
<%@ page import="com.erp.app.report.genericInquiry.inquirySp.beans.vo.*" %>
<%@ page import="java.util.ArrayList" %>
<%@ page import="com.erp.framework.util.CommonUtil" %>
<%@ page import="com.erp.framework.util.user.User" %>
<%@ page import="com.erp.app.common.ProjectConstants" %>
<jsp:useBean id="genericInquirySearchForm" scope="session" type="com.erp.app.report.genericInquiry.GenericInquirySearchForm" />


<% 	GenericInquiryMasterVO masterVO = genericInquirySearchForm.getGenericInquiryMasterVO();
	User user = (User) session.getAttribute(ProjectConstants.SESSION_USER);
	String userId = user.getUserId();
	String title = "";
	if (masterVO != null) {
		ArrayList list = masterVO.getChilds(InquirySpVO.class);
		if (list.size() > 0) {
			InquirySpVO vo = (InquirySpVO)list.get(0);
			title = CommonUtil.nullToString(vo.getInquiryName());
		}
	}
%>

<template:insert template="/jsp/templates/maint-template.jsp" >
  <template:put name="title" content="<%=title%>" direct="true" />
  <template:put name="moduleId" content="<%=masterVO.getInquiryType()%>" direct="true"/>
  <template:put name="content" content="/jsp/com/erp/app/report/genericInquiry/genericInquiryContent.jsp" />
</template:insert>


